window.onresize=function(){//当窗口改变宽度时执行此函数
    $('#myTable').bootstrapTable('resetView');
    $('#ContractTable').bootstrapTable('resetView');
    $('#reportTable').bootstrapTable('resetView');
}

function DoOnCellHtmlData(cell, row, col, data) {
    var result = "";
    if (typeof data != 'undefined' && data != "") {
       var html = $.parseHTML(data);
        $.each( html, function() {
            if ( typeof $(this).html() === 'undefined' )
                result += $(this).text();
            else if ( typeof $(this).attr('class') === 'undefined' || $(this).hasClass('th-inner') === true )
                result += $(this).html();
        });
    }
    return result;
}
$(document).ready(function() {
    $('#myTable').bootstrapTable('refreshOptions', {
        exportOptions: {
            ignoreColumn: ['0','checkbox'], // or as string array: ['0','checkbox']
            onCellHtmlData: DoOnCellHtmlData
        }
   });
    $('#reportTable').bootstrapTable('refreshOptions', {
        exportOptions: {
            ignoreColumn: ['0','checkbox'], // or as string array: ['0','checkbox']
            onCellHtmlData: DoOnCellHtmlData
        }
   });
});
//给oneTable第一个表格增加编辑和增加按钮
function actionFormatter(value, row, index) {
    return [
        '<a id="btn_inquire" class="Inquire">查询</a>'+
        '<a id="btn_Contract" class="Contract">合约</a>'+
        '<a id="btn_Edit" class="Edit">编辑</a>'+
        '<a id="btn_detail" class="Del">删除</a>'
    ].join('');
}

window.actionEvents = {
    'click #btn_inquire': function (e, value, row, index) {
    
    }
};

//给oneTable第一个表格增加编辑和增加按钮
function reportFormatter(value, row, index) {
    return [
        '<a id="btn_view" class="Inquire">查看</a>'
    ].join('');
}